/**
 * 
 */
package biz.innovasoft.test.units;

import biz.innovasoft.nodb.UpdateValidator;
import biz.innovasoft.test.model.Person;

public class PersonChangeNameValidator implements UpdateValidator {

	private static final long serialVersionUID = -8664905888771157435L;

	@Override
	public boolean canUpdate(Object oldObject, Object newObject) {
		Person p = (Person)oldObject;
		if (p.getName().equals ("Darky")) {
			return false;
		}
		return true;
	}

}